import * as proto from "../../../../core/protoc/ts/proto.js";
import phoenixIns from "../../../Phoenix";
import { PhoenixEventDefine } from "../../../defines/event.define";
import { Opcode } from "../../../defines/opcode.define";
import { IMessageHandle } from "../../../interface/IMessageHandle";
import messageManager from "../../../managers/message.manager";

export default class S2CKickHandle implements IMessageHandle{
    handleMessage(msgData: any): void {
        let response = msgData as proto.s2c_kick;
        console.log("OnS2CKickHandle", response);
        phoenixIns.EmitEvent(PhoenixEventDefine.PHOENIX_GAME_ACCOUNT_KICK, response);
    }
}

messageManager.registerHandle(Opcode.Opcode_SC_KICK, new S2CKickHandle());